<?php
	class Prodect_catalog_model extends CI_Model {
		public $table_name="prodect_catalog";
  
     public function get_pc()
    {
        $prodect_catalog=$this->db->where('parent_id',0)->get($this->table_name);
        return $prodect_catalog->result();
    }
      public function get_one_pc($catalog_id)
    {
        $prodect_catalog=$this->db->where('id',$catalog_id)->get($this->table_name);
        return $prodect_catalog->row();
    }
        public function get_child_pc($catalog_id)
    {    
         $prodect_catalog=$this->db->where('parent_id',$catalog_id)->get($this->table_name);
         return $prodect_catalog->result();
    }
        
}
    
